Contributed packages worth knowing about

Packages from JuliaStats

The Distributions package

The Distributions package provides a comprehensive list of univariate, multivariate and matrix distributions and a set of generic functions that can be applied to them. See the documentation for details on the coverage.

Note that some methods refer to the distribution type (e.g. Normal) instead of a distribution instance (e.g. Normal(0.,1.))


In [1]:
using Distributions
d = Normal()        # standard normal (Gaussian) distribution


Out[1]:
Distributions.Normal(μ=0.0, σ=1.0)

In [2]:
x = rand(d,20)     # sample of size 20 from a standard normal


Out[2]:
20-element Array{Float64,1}:
 -1.37163 
  0.108703
 -0.614373
  0.908453
 -0.616237
  1.30055 
  1.82147 
  1.56462 
  1.27457 
 -0.407733
 -0.691858
 -1.49719 
  0.850856
 -0.250366
  1.22701 
 -1.0103  
 -0.47893 
  0.512367
 -0.433555
  0.818587

In [3]:
de = fit_mle(Normal,x)   # maximum likelihood estimates of normal dist. pars.


Out[3]:
Distributions.Normal(μ=0.15075083842683862, σ=0.9912678731753393)

In [4]:
mean(de)


Out[4]:
0.15075083842683862

In [5]:
std(de)


Out[5]:
0.9912678731753393

In [6]:
var(de)


Out[6]:
0.9826119963895605

In [7]:
kurtosis(de)


Out[7]:
0.0

In [8]:
skewness(de)


Out[8]:
0.0

In [9]:
loglikelihood(de,x)


Out[9]:
-28.203361159103117

In [10]:
ss = suffstats(Normal,x)


Out[10]:
Distributions.NormalStats(3.0150167685367726,0.15075083842683862,19.65223992779121,20.0)

In [11]:
fieldnames(ss)'


Out[11]:
1x4 Array{Symbol,2}:
 :s  :m  :s2  :tw

In [12]:
fit_mle(Normal,ss)   # can fit from sufficient statistics


Out[12]:
Distributions.Normal(μ=0.15075083842683862, σ=0.9912678731753393)

It is also possible to do map (maximum a posteriori) estimation using a conjugate prior. Again, see the documentation.

The DataArrays package

This is a lightweight package to define types that can contain NA's. It was split off from the DataFrames package because loading the whole of DataFrames takes a while. (This will change when pre-compiled packages are more easily constructed.)

The basic types defined in DataArrays are NA, used for literal NA input, the DataArray, like a numeric or integer vector in R, and the PooledDataVector, like a factor in R.

The concept of an NA is built into many of the R types. In Julia a DataArray or PooledDataArray is composed of the data and a separate bitarray of indicators of missingness.


In [2]:
using DataArrays
v = @data([2,1,NA,4])


Out[2]:
4-element DataArrays.DataArray{Int64,1}:
 2  
 1  
  NA
 4  

In [14]:
fieldnames(v)


Out[14]:
2-element Array{Symbol,1}:
 :data
 :na  

In [15]:
typeof(v).types


Out[15]:
svec(Array{Int64,1},BitArray{1})

In [16]:
v.data


Out[16]:
4-element Array{Int64,1}:
 2
 1
 2
 4

In [17]:
v.na


Out[17]:
4-element BitArray{1}:
 false
 false
  true
 false

In [18]:
isna(v)


Out[18]:
4-element BitArray{1}:
 false
 false
  true
 false

In [19]:
dropna(v)


Out[19]:
3-element Array{Int64,1}:
 2
 1
 4

The PooledDataArray, generated with the @pdata macro call, consists of a pool array (similar to the levels in an R factor object) and a unsigned integer vector refs.


In [20]:
d = Bernoulli()
sex = @pdata [rand(d)  0 ? 'F' : 'M' for i in 1:1000]


Out[20]:
1000-element DataArrays.PooledDataArray{Char,UInt32,1}:
 'M'
 'F'
 'M'
 'M'
 'M'
 'F'
 'F'
 'F'
 'M'
 'F'
 'M'
 'F'
 'F'
 ⋮  
 'M'
 'F'
 'M'
 'F'
 'F'
 'F'
 'M'
 'F'
 'F'
 'F'
 'F'
 'M'

In [21]:
sex.pool


Out[21]:
2-element Array{Char,1}:
 'F'
 'M'

In [22]:
sex.refs


Out[22]:
1000-element Array{UInt32,1}:
 0x00000002
 0x00000001
 0x00000002
 0x00000002
 0x00000002
 0x00000001
 0x00000001
 0x00000001
 0x00000002
 0x00000001
 0x00000002
 0x00000001
 0x00000001
          ⋮
 0x00000002
 0x00000001
 0x00000002
 0x00000001
 0x00000001
 0x00000001
 0x00000002
 0x00000001
 0x00000001
 0x00000001
 0x00000001
 0x00000002

In [23]:
sex = compact(sex)  # provides a more compact representation, if possible


Out[23]:
1000-element DataArrays.PooledDataArray{Char,UInt8,1}:
 'M'
 'F'
 'M'
 'M'
 'M'
 'F'
 'F'
 'F'
 'M'
 'F'
 'M'
 'F'
 'F'
 ⋮  
 'M'
 'F'
 'M'
 'F'
 'F'
 'F'
 'M'
 'F'
 'F'
 'F'
 'F'
 'M'

In [24]:
sex.refs


Out[24]:
1000-element Array{UInt8,1}:
 0x02
 0x01
 0x02
 0x02
 0x02
 0x01
 0x01
 0x01
 0x02
 0x01
 0x02
 0x01
 0x01
    ⋮
 0x02
 0x01
 0x02
 0x01
 0x01
 0x01
 0x02
 0x01
 0x01
 0x01
 0x01
 0x02

A few other functions common to an R programmer, like rep, are in the DataArrays package.


In [3]:
whos(DataArrays)


                             /     38 KB     Function
WARNING: both StatsBase and Base export "histrange"; uses of it in module DataArrays must be qualified
WARNING: both StatsBase and Base export "midpoints"; uses of it in module DataArrays must be qualified
                         @data   1533 bytes  Function
                        @pdata   1249 bytes  Function
             AbstractDataArray    188 bytes  DataType
            AbstractDataMatrix     80 bytes  TypeConstructor
            AbstractDataVector     80 bytes  TypeConstructor
             AbstractHistogram    228 bytes  DataType
                     CoefTable    284 bytes  DataType
                     DataArray    220 bytes  DataType
                    DataArrays    674 KB     Module
                    DataMatrix     80 bytes  TypeConstructor
                    DataVector     80 bytes  TypeConstructor
                    EachDropNA    168 bytes  DataType
                    EachFailNA    168 bytes  DataType
                 EachReplaceNA    220 bytes  DataType
                      FastPerm    284 bytes  DataType
                     Histogram    272 bytes  DataType
                        L1dist   1279 bytes  Function
                        L2dist    577 bytes  Function
                      Linfdist   1450 bytes  Function
                            NA      0 bytes  DataArrays.NAtype
                   NAException    112 bytes  DataType
                        NAtype     92 bytes  DataType
               PooledDataArray    260 bytes  DataType
              PooledDataMatrix    120 bytes  TypeConstructor
                PooledDataVecs   8507 bytes  Function
              PooledDataVector    120 bytes  TypeConstructor
               RegressionModel     92 bytes  DataType
              StatisticalModel     92 bytes  DataType
                     StatsBase    476 KB     Module
                     WeightVec    284 bytes  DataType
                    addcounts!     14 KB     Function
                         allna   1744 bytes  Function
                         anyna   1708 bytes  Function
                         array   5595 bytes  Function
                       autocor   1089 bytes  Function
                      autocor!   3572 bytes  Function
                       autocov   4814 bytes  Function
                      autocov!   3572 bytes  Function
                          coef    516 bytes  Function
                     coeftable    516 bytes  Function
                       compact   1438 bytes  Function
                   competerank    649 bytes  Function
                       confint    516 bytes  Function
                    corkendall   5773 bytes  Function
                   corspearman   3260 bytes  Function
                       counteq   1287 bytes  Function
                      countmap   2176 bytes  Function
                       countne   1287 bytes  Function
                        counts   8052 bytes  Function
                      crosscor   8202 bytes  Function
                     crosscor!   6952 bytes  Function
                      crosscov   8202 bytes  Function
                     crosscov!   6952 bytes  Function
                  crossentropy   2134 bytes  Function
                           cut   3992 bytes  Function
                          data    504 bytes  Function
                     denserank    647 bytes  Function
                      describe    560 bytes  Function
                      deviance    516 bytes  Function
                   df_residual    516 bytes  Function
                        dropna   2555 bytes  Function
                   each_dropna    557 bytes  Function
                   each_failNA    617 bytes  Function
                   each_failna    557 bytes  Function
                each_replaceNA    629 bytes  Function
                each_replacena   1015 bytes  Function
                          ecdf    948 bytes  Function
                       entropy   1799 bytes  Function
                        findat    538 bytes  Function
                           fit     13 KB     Function
                          fit!    548 bytes  Function
                        fitted    516 bytes  Function
                       geomean   1163 bytes  Function
                    getpoolidx   2027 bytes  Function
                        gkldiv   1559 bytes  Function
                            gl   2271 bytes  Function
                      harmmean   1153 bytes  Function
                          head    592 bytes  Function
                          hist   2683 bytes  Function
                      indexmap   1184 bytes  Function
                  indicatormat   4556 bytes  Function
                   inverse_rle   1942 bytes  Function
                   invsoftplus   5037 bytes  Function
                           iqr    608 bytes  Function
                          isna   4945 bytes  Function
                  kldivergence   2138 bytes  Function
                      kurtosis   5279 bytes  Function
                        levels   1717 bytes  Function
                     levelsmap   1320 bytes  Function
                      logistic   4468 bytes  Function
                         logit   4441 bytes  Function
                 loglikelihood    516 bytes  Function
                     logsumexp   2785 bytes  Function
                           mad   3645 bytes  Function
                         maxad    570 bytes  Function
                  mean_and_cov   2938 bytes  Function
                  mean_and_std   2120 bytes  Function
                  mean_and_var   2120 bytes  Function
                        meanad    585 bytes  Function
                        middle   3053 bytes  Function
                          mode   4046 bytes  Function
                model_response    516 bytes  Function
                         modes   4963 bytes  Function
                        moment   2360 bytes  Function
                           msd    587 bytes  Function
                          nobs    516 bytes  Function
                     nquantile    590 bytes  Function
                   ordinalrank    645 bytes  Function
                          pacf   3226 bytes  Function
                         pacf!   1893 bytes  Function
                         padNA   1240 bytes  Function
                         pdata    516 bytes  Function
                percent_change   1169 bytes  Function
                    percentile    583 bytes  Function
                       predict    516 bytes  Function
                      predict!    516 bytes  Function
                 proportionmap   1003 bytes  Function
                   proportions   7036 bytes  Function
                          psnr    655 bytes  Function
                       reldiff   1140 bytes  Function
                      removeNA    601 bytes  Function
                       reorder   1040 bytes  Function
                           rep   6024 bytes  Function
                      replace!   4684 bytes  Function
                     residuals    516 bytes  Function
                           rle   6285 bytes  Function
                          rmsd   1691 bytes  Function
                        sample   9170 bytes  Function
                       sample!   3510 bytes  Function
                    samplepair   1447 bytes  Function
                    scattermat   3208 bytes  Function
                           sem    568 bytes  Function
                    set_levels    611 bytes  Function
                   set_levels!    615 bytes  Function
                     setlevels   3164 bytes  Function
                    setlevels!   4791 bytes  Function
                      skewness   5199 bytes  Function
                       softmax    560 bytes  Function
                      softmax!   2515 bytes  Function
                      softplus   5021 bytes  Function
                          span    742 bytes  Function
                      sqL2dist   1276 bytes  Function
                        stderr    517 bytes  Function
                  summarystats   1004 bytes  Function
                          tail    607 bytes  Function
                      tiedrank    646 bytes  Function
                      trimmean   1904 bytes  Function
                     variation   1035 bytes  Function
                          vcov    516 bytes  Function
                          view   4098 bytes  Function
                       weights   1086 bytes  Function
                         wmean    723 bytes  Function
                       wmedian   1071 bytes  Function
                     wquantile   2130 bytes  Function
                       wsample   4621 bytes  Function
                      wsample!   1945 bytes  Function
                          wsum   1775 bytes  Function
                         wsum!   1904 bytes  Function
                         xlogx   4467 bytes  Function
                         xlogy   5141 bytes  Function
                          xtab    180 bytes  DataType
                         xtabs   1041 bytes  Function
                        zscore   3008 bytes  Function
                       zscore!   2904 bytes  Function

The DataFrames package

The DataFrame type and methods for working with it are defined in the DataFrames package. There is online documentation but, at least in my browser, the formatting is horrible. I would recommend reading the PDF file instead.

The DataFrames package is where the formula language and types like ModelFrame and ModelMatrix are defined. Many familiar examples of data frames are available in the RDatasets package.


In [26]:
using DataFrames, RDatasets
ds = dataset("lme4","Dyestuff")


Out[26]:
BatchYield
1A1545
2A1440
3A1440
4A1520
5A1580
6B1540
7B1555
8B1490
9B1560
10B1495
11C1595
12C1550
13C1605
14C1510
15C1560
16D1445
17D1440
18D1595
19D1465
20D1545
21E1595
22E1630
23E1515
24E1635
25E1625
26F1520
27F1455
28F1450
29F1480
30F1445
                         @data   1533 bytes  Function
                        @pdata   1545 bytes  Function
             AbstractDataArray    188 bytes  DataType
            AbstractDataMatrix     80 bytes  TypeConstructor
            AbstractDataVector     80 bytes  TypeConstructor
             AbstractHistogram    228 bytes  DataType
                     CoefTable    284 bytes  DataType
                     DataArray    220 bytes  DataType
                    DataArrays    803 KB     Module
                    DataMatrix     80 bytes  TypeConstructor
                    DataVector     80 bytes  TypeConstructor
                    EachDropNA    168 bytes  DataType
                    EachFailNA    168 bytes  DataType
                 EachReplaceNA    220 bytes  DataType
                      FastPerm    284 bytes  DataType
                     Histogram    272 bytes  DataType
                        L1dist   1279 bytes  Function
                        L2dist    577 bytes  Function
                      Linfdist   1450 bytes  Function
                            NA      0 bytes  DataArrays.NAtype
                   NAException    112 bytes  DataType
                        NAtype     92 bytes  DataType
               PooledDataArray    260 bytes  DataType
              PooledDataMatrix    120 bytes  TypeConstructor
                PooledDataVecs   8507 bytes  Function
              PooledDataVector    120 bytes  TypeConstructor
               RegressionModel     92 bytes  DataType
              StatisticalModel     92 bytes  DataType
                     StatsBase    601 KB     Module
                     WeightVec    284 bytes  DataType
                    addcounts!     14 KB     Function
                         allna   1744 bytes  Function
                         anyna   1708 bytes  Function
                         array   5595 bytes  Function
                       autocor   1089 bytes  Function
                      autocor!   3572 bytes  Function
                       autocov   4814 bytes  Function
                      autocov!   3572 bytes  Function
                          coef    516 bytes  Function
                     coeftable    516 bytes  Function
                       compact   3324 bytes  Function
                   competerank    649 bytes  Function
                       confint    516 bytes  Function
                    corkendall   5773 bytes  Function
                   corspearman   3260 bytes  Function
                       counteq   1287 bytes  Function
                      countmap   2176 bytes  Function
                       countne   1287 bytes  Function
                        counts   8052 bytes  Function
                      crosscor   8202 bytes  Function
                     crosscor!   6952 bytes  Function
                      crosscov   8202 bytes  Function
                     crosscov!   6952 bytes  Function
                  crossentropy   2134 bytes  Function
                           cut   3992 bytes  Function
                          data    504 bytes  Function
                     denserank    647 bytes  Function
                      describe    560 bytes  Function
                      deviance    516 bytes  Function
                   df_residual    516 bytes  Function
                        dropna   3439 bytes  Function
                   each_dropna    557 bytes  Function
                   each_failNA    617 bytes  Function
                   each_failna    557 bytes  Function
                each_replaceNA    629 bytes  Function
                each_replacena   1015 bytes  Function
                          ecdf    948 bytes  Function
                       entropy     31 KB     Function
                        findat    538 bytes  Function
                           fit     18 KB     Function
                          fit!    548 bytes  Function
                        fitted    516 bytes  Function
                       geomean   1163 bytes  Function
                    getpoolidx   2027 bytes  Function
                        gkldiv   1559 bytes  Function
                            gl   2271 bytes  Function
                      harmmean   1153 bytes  Function
                          head    592 bytes  Function
                          hist   2683 bytes  Function
                      indexmap   1184 bytes  Function
                  indicatormat   4556 bytes  Function
                   inverse_rle   1942 bytes  Function
                   invsoftplus   5037 bytes  Function
                           iqr    608 bytes  Function
                          isna   5623 bytes  Function
                  kldivergence   2638 bytes  Function
                      kurtosis     38 KB     Function
                        levels   1717 bytes  Function
                     levelsmap   1320 bytes  Function
                      logistic   4468 bytes  Function
                         logit   4441 bytes  Function
                 loglikelihood   2394 bytes  Function
                     logsumexp   2785 bytes  Function
                           mad   3645 bytes  Function
                         maxad    570 bytes  Function
                  mean_and_cov   2938 bytes  Function
                  mean_and_std   2120 bytes  Function
                  mean_and_var   2120 bytes  Function
                        meanad    585 bytes  Function
                        middle   3053 bytes  Function
                          mode     31 KB     Function
                model_response    516 bytes  Function
                         modes     14 KB     Function
                        moment   2360 bytes  Function
                           msd    587 bytes  Function
                          nobs    516 bytes  Function
                     nquantile    590 bytes  Function
                   ordinalrank    645 bytes  Function
                          pacf   3226 bytes  Function
                         pacf!   1893 bytes  Function
                         padNA   1240 bytes  Function
                         pdata    516 bytes  Function
                percent_change   1169 bytes  Function
                    percentile    583 bytes  Function
                       predict    516 bytes  Function
                      predict!    516 bytes  Function
                 proportionmap   1003 bytes  Function
                   proportions   7036 bytes  Function
                          psnr    655 bytes  Function
                       reldiff   1140 bytes  Function
                      removeNA    601 bytes  Function
                       reorder   1040 bytes  Function
                           rep   6024 bytes  Function
                      replace!   4684 bytes  Function
                     residuals    516 bytes  Function
                           rle   6285 bytes  Function
                          rmsd   1691 bytes  Function
                        sample   9170 bytes  Function
                       sample!   3510 bytes  Function
                    samplepair   1447 bytes  Function
                    scattermat   3208 bytes  Function
                           sem    568 bytes  Function
                    set_levels    611 bytes  Function
                   set_levels!    615 bytes  Function
                     setlevels   3164 bytes  Function
                    setlevels!   4791 bytes  Function
                      skewness     36 KB     Function
                       softmax    560 bytes  Function
                      softmax!   2515 bytes  Function
                      softplus   5021 bytes  Function
                          span    742 bytes  Function
                      sqL2dist   1276 bytes  Function
                        stderr    517 bytes  Function
                  summarystats   1004 bytes  Function
                          tail    607 bytes  Function
                      tiedrank    646 bytes  Function
                      trimmean   1904 bytes  Function
                     variation   1035 bytes  Function
                          vcov    516 bytes  Function
                          view   4098 bytes  Function
                       weights   1086 bytes  Function
                         wmean    723 bytes  Function
                       wmedian   1071 bytes  Function
                     wquantile   2130 bytes  Function
                       wsample   4621 bytes  Function
                      wsample!   1945 bytes  Function
                          wsum   1775 bytes  Function
                         wsum!   1904 bytes  Function
                         xlogx   4467 bytes  Function
                         xlogy   5141 bytes  Function
                          xtab    180 bytes  DataType
                         xtabs   1041 bytes  Function
                        zscore   3008 bytes  Function
                       zscore!   2904 bytes  Function
WARNING: Base.String is deprecated, use AbstractString instead.
  likely near /home/bates/.julia/v0.4/RDatasets/src/dataset.jl:1
WARNING: Base.String is deprecated, use AbstractString instead.
  likely near /home/bates/.julia/v0.4/RDatasets/src/dataset.jl:1
WARNING: Base.String is deprecated, use AbstractString instead.
  likely near /home/bates/.julia/v0.4/RDatasets/src/datasets.jl:1

In [27]:
names(ds)


Out[27]:
2-element Array{Symbol,1}:
 :Batch
 :Yield

Indivual columns can be accessed by name using symbols (e.g. :Yield). This means that the column names should be valid Julia identifiers. Among other things, they cannot contain the dot or period character (.).


In [28]:
ds[:Yield]


Out[28]:
30-element DataArrays.DataArray{Int32,1}:
 1545
 1440
 1440
 1520
 1580
 1540
 1555
 1490
 1560
 1495
 1595
 1550
 1605
    ⋮
 1465
 1545
 1595
 1630
 1515
 1635
 1625
 1520
 1455
 1450
 1480
 1445

The DataFrame constructor can be given <name>=<value> pairs.


In [29]:
x = 1.:10.;
ϵ = rand(Normal(0.,0.1),length(x));
β = [4.2,1.1];
ytrue = [ones(length(x)) x]*β;
dd = DataFrame(x=x,ytrue = ytrue, y = ytrue + ϵ)


Out[29]:
xytruey
11.05.3000000000000015.4266459954573465
22.06.46.547618585779938
33.07.57.4126925420952325
44.08.6000000000000018.502478506094308
55.09.79.459142933970893
66.010.810.798058744556116
77.011.90000000000000211.791803744236113
88.013.013.131877566162375
99.014.10000000000000114.145992654678988
1010.015.215.120811027815394

In R many modeling functions that use a formula/data representation first apply model.frame then model.matrix. In the DataFrames package these are ModelFrame and ModelMatrix. A ModelFrame is the reduction of the original DataFrame to only those columns that are used in the model and after application of the NA action. It includes a Terms object, which describes the terms in the formula, again after some reduction and expansion. Finally, a record is kept of which rows in the original data frame are represented in the derived frame.


In [30]:
mf = ModelFrame(y ~ x, dd)


Out[30]:
DataFrames.ModelFrame(10x2 DataFrames.DataFrame
| Row | y       | x    |
|-----|---------|------|
| 1   | 5.42665 | 1.0  |
| 2   | 6.54762 | 2.0  |
| 3   | 7.41269 | 3.0  |
| 4   | 8.50248 | 4.0  |
| 5   | 9.45914 | 5.0  |
| 6   | 10.7981 | 6.0  |
| 7   | 11.7918 | 7.0  |
| 8   | 13.1319 | 8.0  |
| 9   | 14.146  | 9.0  |
| 10  | 15.1208 | 10.0 |,DataFrames.Terms(Any[:x],Any[:y,:x],2x2 Array{Int8,2}:
 1  0
 0  1,[1,1],true,true),Bool[true,true,true,true,true,true,true,true,true,true])

The ModelMatrix is constructed from the ModelFrame.


In [31]:
mm = ModelMatrix(mf)


Out[31]:
DataFrames.ModelMatrix{Float64}(10x2 Array{Float64,2}:
 1.0   1.0
 1.0   2.0
 1.0   3.0
 1.0   4.0
 1.0   5.0
 1.0   6.0
 1.0   7.0
 1.0   8.0
 1.0   9.0
 1.0  10.0,[0,1])

The assign vector in this object maps columns to terms. It is used when performing hypothesis tests, like anova. At present the model_response function returns the value of the expression on the left-hand side of the formula.


In [32]:
model_response(mf)


Out[32]:
10-element Array{Float64,1}:
  5.42665
  6.54762
  7.41269
  8.50248
  9.45914
 10.7981 
 11.7918 
 13.1319 
 14.146  
 15.1208 

These facilities are not developed as fully as those in R.

The GLM Package

The GLM package provides functions to fit and analyse the linear models and generalized linear models.


In [33]:
using GLM
fm = lm(y ~ x, dd)


Out[33]:
DataFrames.DataFrameRegressionModel{GLM.LinearModel{GLM.LmResp{Array{Float64,1}},GLM.DensePredQR{Float64}},Float64}:

Coefficients:
             Estimate Std.Error t value Pr(>|t|)
(Intercept)   4.22575 0.0913301  46.269   <1e-10
x             1.09236 0.0147192 74.2132   <1e-11

In [34]:
fm = fit(LinearModel,y ~ x,dd)


Out[34]:
DataFrames.DataFrameRegressionModel{GLM.LinearModel{GLM.LmResp{Array{Float64,1}},GLM.DensePredQR{Float64}},Float64}:

Coefficients:
             Estimate Std.Error t value Pr(>|t|)
(Intercept)   4.22575 0.0913301  46.269   <1e-10
x             1.09236 0.0147192 74.2132   <1e-11

StatsBase

The StatsBase package contains functions for sample statistics and many utilities. There is online documentation. Much of the design and implementation is by Dahua Lin who is a stickler for extracting every last ounce of performance.


In [1]:
using StatsBase
whos(StatsBase)


             AbstractHistogram    228 bytes  DataType
                     CoefTable    284 bytes  DataType
                     Histogram    272 bytes  DataType
                        L1dist   1279 bytes  Function
                        L2dist    577 bytes  Function
                      Linfdist   1450 bytes  Function
               RegressionModel     92 bytes  DataType
              StatisticalModel     92 bytes  DataType
                     StatsBase    470 KB     Module
                     WeightVec    284 bytes  DataType
                    addcounts!     11 KB     Function
                       autocor   4814 bytes  Function
                      autocor!   3572 bytes  Function
                       autocov   4814 bytes  Function
                      autocov!   3572 bytes  Function
                          coef    516 bytes  Function
                     coeftable    516 bytes  Function
                   competerank    649 bytes  Function
                       confint    516 bytes  Function
                    corkendall   5773 bytes  Function
                   corspearman   2532 bytes  Function
                       counteq   1287 bytes  Function
                      countmap   1118 bytes  Function
                       countne   1287 bytes  Function
                        counts   8052 bytes  Function
                      crosscor   8202 bytes  Function
                     crosscor!   6952 bytes  Function
                      crosscov   8202 bytes  Function
                     crosscov!   6952 bytes  Function
                  crossentropy   2134 bytes  Function
                     denserank    647 bytes  Function
                      describe    560 bytes  Function
                      deviance    516 bytes  Function
                   df_residual    516 bytes  Function
                          ecdf    948 bytes  Function
                       entropy   1799 bytes  Function
                        findat    538 bytes  Function
                           fit     13 KB     Function
                          fit!    548 bytes  Function
                        fitted    516 bytes  Function
                       geomean   1163 bytes  Function
                        gkldiv   1559 bytes  Function
                      harmmean   1153 bytes  Function
                          hist   2683 bytes  Function
                     histrange   5943 bytes  Function
                      indexmap   1184 bytes  Function
                  indicatormat   4556 bytes  Function
                   inverse_rle   1798 bytes  Function
                   invsoftplus   5037 bytes  Function
                           iqr    608 bytes  Function
                  kldivergence   2138 bytes  Function
                      kurtosis   4745 bytes  Function
                     levelsmap   1320 bytes  Function
                      logistic   4468 bytes  Function
                         logit   4441 bytes  Function
                 loglikelihood    516 bytes  Function
                     logsumexp   2785 bytes  Function
                           mad   3116 bytes  Function
                         maxad    570 bytes  Function
                  mean_and_cov   2938 bytes  Function
                  mean_and_std   2120 bytes  Function
                  mean_and_var   2120 bytes  Function
                        meanad    585 bytes  Function
                        middle   3053 bytes  Function
                     midpoints   1657 bytes  Function
                          mode   4046 bytes  Function
                model_response    516 bytes  Function
                         modes   4963 bytes  Function
                        moment   2360 bytes  Function
                           msd    587 bytes  Function
                          nobs    516 bytes  Function
                     nquantile    590 bytes  Function
                   ordinalrank    645 bytes  Function
                          pacf   3226 bytes  Function
                         pacf!   1893 bytes  Function
                    percentile    583 bytes  Function
                       predict    516 bytes  Function
                      predict!    516 bytes  Function
                 proportionmap   1003 bytes  Function
                   proportions   7036 bytes  Function
                          psnr    655 bytes  Function
                     residuals    516 bytes  Function
                           rle   1824 bytes  Function
                          rmsd   1691 bytes  Function
                        sample   9170 bytes  Function
                       sample!   3510 bytes  Function
                    samplepair   1447 bytes  Function
                    scattermat   3208 bytes  Function
                           sem    568 bytes  Function
                      skewness   4665 bytes  Function
                       softmax    560 bytes  Function
                      softmax!   2515 bytes  Function
                      softplus   5021 bytes  Function
                          span    742 bytes  Function
                      sqL2dist   1276 bytes  Function
                        stderr    517 bytes  Function
                  summarystats   1004 bytes  Function
                      tiedrank    646 bytes  Function
                      trimmean   1904 bytes  Function
                     variation   1035 bytes  Function
                          vcov    516 bytes  Function
                          view   4098 bytes  Function
                       weights   1086 bytes  Function
                         wmean    723 bytes  Function
                       wmedian   1071 bytes  Function
                     wquantile   2130 bytes  Function
                       wsample   4621 bytes  Function
                      wsample!   1945 bytes  Function
                          wsum   1775 bytes  Function
                         wsum!   1904 bytes  Function
                         xlogx   4467 bytes  Function
                         xlogy   5141 bytes  Function
                        zscore   3008 bytes  Function
                       zscore!   2904 bytes  Function

MLBase

The MLBase package contains many functions for data manipulation and reduction. It uses the Machine Learning (ML) terminology.


In [5]:
using MLBase
whos(MLBase)


WARNING: Base.String is deprecated, use AbstractString instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/modeltune.jl:5
WARNING: Base.String is deprecated, use AbstractString instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/modeltune.jl:5
WARNING: Base.String is deprecated, use AbstractString instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/modeltune.jl:5
WARNING: Base.FloatingPoint is deprecated, use AbstractFloat instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/deprecated/datapre.jl:104
WARNING: Base.FloatingPoint is deprecated, use AbstractFloat instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/deprecated/datapre.jl:105
WARNING: Base.FloatingPoint is deprecated, use AbstractFloat instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/deprecated/datapre.jl:163
WARNING: Base.FloatingPoint is deprecated, use AbstractFloat instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/deprecated/datapre.jl:163
WARNING: Base.FloatingPoint is deprecated, use AbstractFloat instead.
  likely near /home/juser/.julia/v0.4/MLBase/src/deprecated/datapre.jl:163
             AbstractHistogram    228 bytes  DataType
WARNING: both StatsBase and Base export "histrange"; uses of it in module MLBase must be qualified
WARNING: both StatsBase and Base export "midpoints"; uses of it in module MLBase must be qualified
                     CoefTable    284 bytes  DataType
             CrossValGenerator     92 bytes  DataType
                       Forward      0 bytes  Base.Order.ForwardOrdering
                     Histogram    272 bytes  DataType
                         Kfold    136 bytes  DataType
                        L1dist   1279 bytes  Function
                        L2dist    577 bytes  Function
                         LOOCV    112 bytes  DataType
                      LabelMap    180 bytes  DataType
                      Linfdist   1450 bytes  Function
                        MLBase    369 KB     Module
                       ROCNums    228 bytes  DataType
                     RandomSub    136 bytes  DataType
               RegressionModel     92 bytes  DataType
                       Reverse      0 bytes  Base.Order.ReverseOrdering{Base.Or…
                   Standardize    136 bytes  DataType
              StatisticalModel     92 bytes  DataType
                     StatsBase    470 KB     Module
               StratifiedKfold    148 bytes  DataType
           StratifiedRandomSub    148 bytes  DataType
                     WeightVec    284 bytes  DataType
                    addcounts!     11 KB     Function
                       autocor   4814 bytes  Function
                      autocor!   3572 bytes  Function
                       autocov   4814 bytes  Function
                      autocov!   3572 bytes  Function
                      classify   4926 bytes  Function
                     classify!   3564 bytes  Function
            classify_withscore   1934 bytes  Function
           classify_withscores   1325 bytes  Function
          classify_withscores!   2395 bytes  Function
                          coef    516 bytes  Function
                     coeftable    516 bytes  Function
                   competerank    649 bytes  Function
                       confint    516 bytes  Function
                     confusmat   1518 bytes  Function
                    corkendall   5773 bytes  Function
                   correctrate    611 bytes  Function
                   corspearman   2532 bytes  Function
                       counteq   1287 bytes  Function
                     counthits   4733 bytes  Function
                      countmap   1118 bytes  Function
                       countne   1287 bytes  Function
                        counts   8052 bytes  Function
                cross_validate   2492 bytes  Function
                      crosscor   8202 bytes  Function
                     crosscor!   6952 bytes  Function
                      crosscov   8202 bytes  Function
                     crosscov!   6952 bytes  Function
                  crossentropy   2134 bytes  Function
                     denserank    647 bytes  Function
                      describe    560 bytes  Function
                      deviance    516 bytes  Function
                   df_residual    516 bytes  Function
                          ecdf    948 bytes  Function
                       entropy   1799 bytes  Function
                     errorrate    611 bytes  Function
                       f1score    604 bytes  Function
                false_negative    496 bytes  Function
           false_negative_rate    521 bytes  Function
                false_positive    496 bytes  Function
           false_positive_rate    521 bytes  Function
                        findat    538 bytes  Function
                           fit     13 KB     Function
                          fit!    548 bytes  Function
                        fitted    516 bytes  Function
                       geomean   1163 bytes  Function
                        gkldiv   1559 bytes  Function
                      gridtune   2063 bytes  Function
                  groupindices   3382 bytes  Function
                      harmmean   1153 bytes  Function
                          hist   2683 bytes  Function
                       hitrate    731 bytes  Function
                      hitrates   1422 bytes  Function
                      indexmap   1184 bytes  Function
                  indicatormat   4556 bytes  Function
                   inverse_rle   1798 bytes  Function
                   invsoftplus   5037 bytes  Function
                           iqr    608 bytes  Function
                  kldivergence   2138 bytes  Function
                      kurtosis   4745 bytes  Function
                   labeldecode   1648 bytes  Function
                   labelencode   1657 bytes  Function
                      labelmap   1417 bytes  Function
                     levelsmap   1320 bytes  Function
                      logistic   4468 bytes  Function
                         logit   4441 bytes  Function
                 loglikelihood    516 bytes  Function
                     logsumexp   2785 bytes  Function
                           mad   3116 bytes  Function
                         maxad    570 bytes  Function
                  mean_and_cov   2938 bytes  Function
                  mean_and_std   2120 bytes  Function
                  mean_and_var   2120 bytes  Function
                        meanad    585 bytes  Function
                        middle   3053 bytes  Function
                          mode   4046 bytes  Function
                model_response    516 bytes  Function
                         modes   4963 bytes  Function
                        moment   2360 bytes  Function
                           msd    587 bytes  Function
                          nobs    516 bytes  Function
                     nquantile    590 bytes  Function
                   ordinalrank    645 bytes  Function
                          pacf   3226 bytes  Function
                         pacf!   1893 bytes  Function
                    percentile    583 bytes  Function
                     precision   3287 bytes  Function
                       predict    516 bytes  Function
                      predict!    516 bytes  Function
                 proportionmap   1003 bytes  Function
                   proportions   7036 bytes  Function
                          psnr    655 bytes  Function
                        recall    506 bytes  Function
                       repeach   3277 bytes  Function
                    repeachcol   3354 bytes  Function
                    repeachrow   4030 bytes  Function
                     residuals    516 bytes  Function
                           rle   1824 bytes  Function
                          rmsd   1691 bytes  Function
                           roc     15 KB     Function
                        sample   9170 bytes  Function
                       sample!   3510 bytes  Function
                    samplepair   1447 bytes  Function
                    scattermat   3208 bytes  Function
                           sem    568 bytes  Function
                      skewness   4665 bytes  Function
                       softmax    560 bytes  Function
                      softmax!   2515 bytes  Function
                      softplus   5021 bytes  Function
                          span    742 bytes  Function
                      sqL2dist   1276 bytes  Function
                   standardize   1819 bytes  Function
                  standardize!   1821 bytes  Function
                        stderr    517 bytes  Function
                  summarystats   1004 bytes  Function
                      tiedrank    646 bytes  Function
                     transform   1086 bytes  Function
                      trimmean   1904 bytes  Function
                 true_negative    496 bytes  Function
            true_negative_rate    521 bytes  Function
                 true_positive    496 bytes  Function
            true_positive_rate    521 bytes  Function
                     variation   1035 bytes  Function
                          vcov    516 bytes  Function
                          view   4098 bytes  Function
                       weights   1086 bytes  Function
                         wmean    723 bytes  Function
                       wmedian   1071 bytes  Function
                     wquantile   2130 bytes  Function
                       wsample   4621 bytes  Function
                      wsample!   1945 bytes  Function
                          wsum   1775 bytes  Function
                         wsum!   1904 bytes  Function
                         xlogx   4467 bytes  Function
                         xlogy   5141 bytes  Function
                        zscore   3008 bytes  Function
                       zscore!   2904 bytes  Function

RCall


In [7]:
using RCall

In [8]:
form = rcopy("Formaldehyde")


Out[8]:
carboptden
10.10.086
20.30.269
30.50.446
40.60.538
50.70.626
60.90.782

In [9]:
@rimport lme4


WARNING: RCall.jl Loading required package: Matrix

In [10]:
whos(lme4)


                   Arabidopsis      8 bytes  RCall.RObject{RCall.VecSxp}
                      Cv_to_Sv      8 bytes  RCall.RObject{RCall.ClosSxp}
                      Cv_to_Vv      8 bytes  RCall.RObject{RCall.ClosSxp}
                      Dyestuff      8 bytes  RCall.RObject{RCall.VecSxp}
                     Dyestuff2      8 bytes  RCall.RObject{RCall.VecSxp}
                        GHrule      8 bytes  RCall.RObject{RCall.ClosSxp}
                           GQN      8 bytes  RCall.RObject{RCall.VecSxp}
                          GQdk      8 bytes  RCall.RObject{RCall.ClosSxp}
                      InstEval      8 bytes  RCall.RObject{RCall.VecSxp}
                    NelderMead      8 bytes  RCall.RObject{RCall.ClosSxp}
                   Nelder_Mead      8 bytes  RCall.RObject{RCall.ClosSxp}
                        Pastes      8 bytes  RCall.RObject{RCall.VecSxp}
                    Penicillin      8 bytes  RCall.RObject{RCall.VecSxp}
                      REMLcrit      8 bytes  RCall.RObject{RCall.ClosSxp}
                      Sv_to_Cv      8 bytes  RCall.RObject{RCall.ClosSxp}
                       VarCorr      8 bytes  RCall.RObject{RCall.ClosSxp}
                       VerbAgg      8 bytes  RCall.RObject{RCall.VecSxp}
                      Vv_to_Cv      8 bytes  RCall.RObject{RCall.ClosSxp}
                       bootMer      8 bytes  RCall.RObject{RCall.ClosSxp}
                          cake      8 bytes  RCall.RObject{RCall.VecSxp}
                          cbpp      8 bytes  RCall.RObject{RCall.VecSxp}
                confint.merMod      8 bytes  RCall.RObject{RCall.ClosSxp}
                     cov2sdcor      8 bytes  RCall.RObject{RCall.ClosSxp}
                       devcomp      8 bytes  RCall.RObject{RCall.ClosSxp}
                         dummy      8 bytes  RCall.RObject{RCall.ClosSxp}
             expandDoubleVerts      8 bytes  RCall.RObject{RCall.ClosSxp}
                     factorize      8 bytes  RCall.RObject{RCall.ClosSxp}
                      findbars      8 bytes  RCall.RObject{RCall.ClosSxp}
                         fixef      8 bytes  RCall.RObject{RCall.ClosSxp}
                      formatVC      8 bytes  RCall.RObject{RCall.ClosSxp}
                fortify.merMod      8 bytes  RCall.RObject{RCall.ClosSxp}
                          getL      8 bytes  RCall.RObject{RCall.ClosSxp}
                         getME      8 bytes  RCall.RObject{RCall.ClosSxp}
                     glFormula      8 bytes  RCall.RObject{RCall.ClosSxp}
                     glmFamily      8 bytes  RCall.RObject{RCall.ClosSxp}
                       glmResp      8 bytes  RCall.RObject{RCall.ClosSxp}
                         glmer      8 bytes  RCall.RObject{RCall.ClosSxp}
                      glmer.nb      8 bytes  RCall.RObject{RCall.ClosSxp}
                  glmerControl      8 bytes  RCall.RObject{RCall.ClosSxp}
            glmerLaplaceHandle      8 bytes  RCall.RObject{RCall.ClosSxp}
                        golden      8 bytes  RCall.RObject{RCall.ClosSxp}
                   grouseticks      8 bytes  RCall.RObject{RCall.VecSxp}
               grouseticks_agg      8 bytes  RCall.RObject{RCall.VecSxp}
                        isGLMM      8 bytes  RCall.RObject{RCall.ClosSxp}
                         isLMM      8 bytes  RCall.RObject{RCall.ClosSxp}
                        isNLMM      8 bytes  RCall.RObject{RCall.ClosSxp}
                      isNested      8 bytes  RCall.RObject{RCall.ClosSxp}
                        isREML      8 bytes  RCall.RObject{RCall.ClosSxp}
                      lFormula      8 bytes  RCall.RObject{RCall.ClosSxp}
                       llikAIC      8 bytes  RCall.RObject{RCall.ClosSxp}
                        lmList      8 bytes  RCall.RObject{RCall.ClosSxp}
                        lmResp      8 bytes  RCall.RObject{RCall.ClosSxp}
                          lme4    756 bytes  Module
                          lmer      8 bytes  RCall.RObject{RCall.ClosSxp}
                   lmerControl      8 bytes  RCall.RObject{RCall.ClosSxp}
                      lmerResp      8 bytes  RCall.RObject{RCall.ClosSxp}
                       logProf      8 bytes  RCall.RObject{RCall.ClosSxp}
                      merPredD      8 bytes  RCall.RObject{RCall.ClosSxp}
                     methTitle      8 bytes  RCall.RObject{RCall.ClosSxp}
                mkDataTemplate      8 bytes  RCall.RObject{RCall.ClosSxp}
                 mkGlmerDevfun      8 bytes  RCall.RObject{RCall.ClosSxp}
                  mkLmerDevfun      8 bytes  RCall.RObject{RCall.ClosSxp}
                      mkMerMod      8 bytes  RCall.RObject{RCall.ClosSxp}
                mkParsTemplate      8 bytes  RCall.RObject{RCall.ClosSxp}
                      mkReTrms      8 bytes  RCall.RObject{RCall.ClosSxp}
                     mkRespMod      8 bytes  RCall.RObject{RCall.ClosSxp}
                     mkVarCorr      8 bytes  RCall.RObject{RCall.ClosSxp}
                     mlist2vec      8 bytes  RCall.RObject{RCall.ClosSxp}
             negative.binomial      8 bytes  RCall.RObject{RCall.ClosSxp}
                         ngrps      8 bytes  RCall.RObject{RCall.ClosSxp}
                     nlformula      8 bytes  RCall.RObject{RCall.ClosSxp}
                         nlmer      8 bytes  RCall.RObject{RCall.ClosSxp}
                  nlmerControl      8 bytes  RCall.RObject{RCall.ClosSxp}
                     nloptwrap      8 bytes  RCall.RObject{RCall.ClosSxp}
                       nlsResp      8 bytes  RCall.RObject{RCall.ClosSxp}
                        nobars      8 bytes  RCall.RObject{RCall.ClosSxp}
                 optimizeGlmer      8 bytes  RCall.RObject{RCall.ClosSxp}
                  optimizeLmer      8 bytes  RCall.RObject{RCall.ClosSxp}
                         ranef      8 bytes  RCall.RObject{RCall.ClosSxp}
                         rePos      8 bytes  RCall.RObject{RCall.ClosSxp}
                         refit      8 bytes  RCall.RObject{RCall.ClosSxp}
                       refitML      8 bytes  RCall.RObject{RCall.ClosSxp}
                     sdcor2cov      8 bytes  RCall.RObject{RCall.ClosSxp}
                          show      8 bytes  RCall.RObject{RCall.ClosSxp}
                         sigma      8 bytes  RCall.RObject{RCall.ClosSxp}
                    sleepstudy      8 bytes  RCall.RObject{RCall.VecSxp}
                       subbars      8 bytes  RCall.RObject{RCall.ClosSxp}
             updateGlmerDevfun      8 bytes  RCall.RObject{RCall.ClosSxp}
                  varianceProf      8 bytes  RCall.RObject{RCall.ClosSxp}
                   vcov.merMod      8 bytes  RCall.RObject{RCall.ClosSxp}
                    vec2STlist      8 bytes  RCall.RObject{RCall.ClosSxp}
                     vec2mlist      8 bytes  RCall.RObject{RCall.ClosSxp}

In [11]:
lme4.grouseticks


Out[11]:
RCall.RObject{RCall.VecSxp}
    INDEX TICKS BROOD HEIGHT YEAR LOCATION    cHEIGHT
1       1     0   501    465   95       32   2.759305
2       2     0   501    465   95       32   2.759305
3       3     0   502    472   95       36   9.759305
4       4     0   503    475   95       37  12.759305
5       5     0   503    475   95       37  12.759305
6       6     3   503    475   95       37  12.759305
7       7     2   503    475   95       37  12.759305
8       8     0   504    488   95       44  25.759305
9       9     0   504    488   95       44  25.759305
10     10     2   504    488   95       44  25.759305
11     11     0   505    492   95       47  29.759305
12     12     0   505    492   95       47  29.759305
13     13     0   505    492   95       47  29.759305
14     14     0   506    490   95       45  27.759305
15     15     0   506    490   95       45  27.759305
16     16     0   506    490   95       45  27.759305
17     17     0   507    464   95       31   1.759305
18     18     0   507    464   95       31   1.759305
19     19     0   507    464   95       31   1.759305
20     20     1   507    464   95       31   1.759305
21     21     2   507    464   95       31   1.759305
22     22     1   509    457   95       28  -5.240695
23     23     0   510    457   95       28  -5.240695
24     24     0   511    457   95       28  -5.240695
25     25     5   511    457   95       28  -5.240695
26     26     8   512    451   95       26 -11.240695
27     27     3   512    451   95       26 -11.240695
28     28     4   512    451   95       26 -11.240695
29     29     7   513    437   95       17 -25.240695
30     30     0   513    437   95       17 -25.240695
31     31     4   513    437   95       17 -25.240695
32     32     4   514    430   95       14 -32.240695
33     33     1   514    430   95       14 -32.240695
34     34     0   514    430   95       14 -32.240695
35     35     0   514    430   95       14 -32.240695
36     36     3   514    430   95       14 -32.240695
37     37     1   514    430   95       14 -32.240695
38     38     6   515    427   95       13 -35.240695
39     39     0   515    427   95       13 -35.240695
40     40     1   515    427   95       13 -35.240695
41     41     0   515    427   95       13 -35.240695
42     42     2   516    419   95        7 -43.240695
43     43     7   516    419   95        7 -43.240695
44     44    31   516    419   95        7 -43.240695
45     45    34   517    411   95        4 -51.240695
46     46    17   517    411   95        4 -51.240695
47     47    16   517    411   95        4 -51.240695
48     48    66   518    419   95        7 -43.240695
49     49    49   518    419   95        7 -43.240695
50     50    82   518    419   95        7 -43.240695
51     51    85   518    419   95        7 -43.240695
52     52    64   518    419   95        7 -43.240695
53     53    11   519    424   95       11 -38.240695
54     54    14   519    424   95       11 -38.240695
55     55     4   519    424   95       11 -38.240695
56     56    10   519    424   95       11 -38.240695
57     57     3   520    427   95       13 -35.240695
58     58    15   520    427   95       13 -35.240695
59     59     8   520    427   95       13 -35.240695
60     60     9   521    422   95        9 -40.240695
61     61    11   521    422   95        9 -40.240695
62     62     7   521    422   95        9 -40.240695
63     63    13   521    422   95        9 -40.240695
64     64     3   522    503   95       53  40.759305
65     65     0   523    496   95       51  33.759305
66     66     0   523    496   95       51  33.759305
67     67     1   523    496   95       51  33.759305
68     68     1   523    496   95       51  33.759305
69     69     0   525    507   95       54  44.759305
70     70     0   525    507   95       54  44.759305
71     71     0   525    507   95       54  44.759305
72     72     0   525    507   95       54  44.759305
73     73     0   526    496   95       51  33.759305
74     74     0   526    496   95       51  33.759305
75     75     0   526    496   95       51  33.759305
76     76     1   526    496   95       51  33.759305
77     77     1   526    496   95       51  33.759305
78     78     0   526    496   95       51  33.759305
79     79     2   528    466   95       33   3.759305
80     80     0   528    466   95       33   3.759305
81     81     3   528    466   95       33   3.759305
82     82     1   531    488   95       44  25.759305
83     83     7   533    442   95       19 -20.240695
84     84     2   533    442   95       19 -20.240695
85     85    16   533    442   95       19 -20.240695
86     86    12   533    442   95       19 -20.240695
87     87     0   533    442   95       19 -20.240695
88     88     1   535    442   95       19 -20.240695
89     89     0   537    533   95       63  70.759305
90     90     0   537    533   95       63  70.759305
91     91     1   537    533   95       63  70.759305
92     92     0   537    533   95       63  70.759305
93     93     0   537    533   95       63  70.759305
94     94     1   537    533   95       63  70.759305
95     95     0   537    533   95       63  70.759305
96     96     0   538    533   95       63  70.759305
97     97     0   539    515   95       59  52.759305
98     98     0   539    515   95       59  52.759305
99     99     0   539    515   95       59  52.759305
100   100     0   539    515   95       59  52.759305
101   101     5   540    518   95       60  55.759305
102   102     2   540    518   95       60  55.759305
103   103     2   542    493   95       48  30.759305
104   104     1   542    493   95       48  30.759305
105   105     1   542    493   95       48  30.759305
106   106     0   548    468   95       34   5.759305
107   107     0   548    468   95       34   5.759305
108   108     1   548    468   95       34   5.759305
109   109     1   549    476   95       38  13.759305
110   110     1   549    476   95       38  13.759305
111   111     0   549    476   95       38  13.759305
112   112     0   549    476   95       38  13.759305
113   113     5   550    446   95       22 -16.240695
114   114     3   550    446   95       22 -16.240695
115   115     2   553    460   95       30  -2.240695
116   116     2   559    525   95       62  62.759305
117   117     1   559    525   95       62  62.759305
118   118     1   601    410   96        3 -52.240695
119   119     0   601    410   96        3 -52.240695
120   120     2   601    410   96        3 -52.240695
121   121     5   601    410   96        3 -52.240695
122   122     1   601    410   96        3 -52.240695
123   123     2   601    410   96        3 -52.240695
124   124     2   601    410   96        3 -52.240695
125   125     3   602    417   96        6 -45.240695
126   126    14   602    417   96        6 -45.240695
127   127    11   602    417   96        6 -45.240695
128   128     9   602    417   96        6 -45.240695
129   129     4   602    417   96        6 -45.240695
130   130    10   602    417   96        6 -45.240695
131   131    33   602    417   96        6 -45.240695
132   132    19   602    417   96        6 -45.240695
133   133    16   602    417   96        6 -45.240695
134   134    16   603    430   96       14 -32.240695
135   135    13   603    430   96       14 -32.240695
136   136    11   603    430   96       14 -32.240695
137   137     7   603    430   96       14 -32.240695
138   138     4   603    430   96       14 -32.240695
139   139    11   603    430   96       14 -32.240695
140   140     1   604    456   96       27  -6.240695
141   141     1   604    456   96       27  -6.240695
142   142     4   604    456   96       27  -6.240695
143   143     6   605    457   96       28  -5.240695
144   144     2   605    457   96       28  -5.240695
145   145     7   605    457   96       28  -5.240695
146   146     8   605    457   96       28  -5.240695
147   147    14   605    457   96       28  -5.240695
148   148     6   606    430   96       14 -32.240695
149   149    13   606    430   96       14 -32.240695
150   150     5   606    430   96       14 -32.240695
151   151     8   606    430   96       14 -32.240695
152   152    13   606    430   96       14 -32.240695
153   153    17   606    430   96       14 -32.240695
154   154     5   606    430   96       14 -32.240695
155   155     1   606    430   96       14 -32.240695
156   156     1   606    430   96       14 -32.240695
157   157     2   606    430   96       14 -32.240695
158   158     7   607    423   96       10 -39.240695
159   159     7   608    421   96        8 -41.240695
160   160    11   608    421   96        8 -41.240695
161   161     1   609    525   96       62  62.759305
162   162     0   609    525   96       62  62.759305
163   163     5   610    509   96       55  46.759305
164   164     4   610    509   96       55  46.759305
165   165     0   611    499   96       52  36.759305
166   166     0   611    499   96       52  36.759305
167   167     0   611    499   96       52  36.759305
168   168     7   612    503   96       53  40.759305
169   169     5   612    503   96       53  40.759305
170   170     3   612    503   96       53  40.759305
171   171     1   612    503   96       53  40.759305
172   172     6   612    503   96       53  40.759305
173   173     1   614    492   96       47  29.759305
174   174     2   614    492   96       47  29.759305
175   175    14   615    491   96       46  28.759305
176   176     5   615    491   96       46  28.759305
177   177    27   615    491   96       46  28.759305
178   178     1   616    475   96       37  12.759305
179   179     2   616    475   96       37  12.759305
180   180     3   616    475   96       37  12.759305
181   181     0   616    475   96       37  12.759305
182   182     1   617    479   96       40  16.759305
183   183     0   617    479   96       40  16.759305
184   184     5   617    479   96       40  16.759305
185   185     5   617    479   96       40  16.759305
186   186     8   617    479   96       40  16.759305
187   187    21   617    479   96       40  16.759305
188   188    15   618    472   96       36   9.759305
189   189    15   618    472   96       36   9.759305
190   190     6   618    472   96       36   9.759305
191   191    19   618    472   96       36   9.759305
192   192    14   618    472   96       36   9.759305
193   193     1   621    485   96       42  22.759305
194   194     1   621    485   96       42  22.759305
195   195     3   621    485   96       42  22.759305
196   196     2   621    485   96       42  22.759305
197   197     3   621    485   96       42  22.759305
198   198     2   623    495   96       50  32.759305
199   199     5   623    495   96       50  32.759305
200   200     0   624    472   96       36   9.759305
201   201     6   624    472   96       36   9.759305
202   202     3   624    472   96       36   9.759305
203   203     1   625    458   96       29  -4.240695
204   204     0   625    458   96       29  -4.240695
205   205     1   625    458   96       29  -4.240695
206   206     6   625    458   96       29  -4.240695
207   207     1   625    458   96       29  -4.240695
208   208    85   626    449   96       24 -13.240695
209   209    45   626    449   96       24 -13.240695
210   210    68   626    449   96       24 -13.240695
211   211    84   626    449   96       24 -13.240695
212   212    50   626    449   96       24 -13.240695
213   213    13   628    442   96       19 -20.240695
214   214     1   628    442   96       19 -20.240695
215   215    19   629    448   96       23 -14.240695
216   216    26   629    448   96       23 -14.240695
217   217     9   629    448   96       23 -14.240695
218   218     2   629    448   96       23 -14.240695
219   219     4   629    448   96       23 -14.240695
220   220     3   629    448   96       23 -14.240695
221   221    22   630    448   96       23 -14.240695
222   222    32   630    448   96       23 -14.240695
223   223     5   631    403   96        1 -59.240695
224   224    21   631    403   96        1 -59.240695
225   225    26   631    403   96        1 -59.240695
226   226    13   631    403   96        1 -59.240695
227   227    23   631    403   96        1 -59.240695
228   228    42   632    411   96        4 -51.240695
229   229    38   632    411   96        4 -51.240695
230   230    61   632    411   96        4 -51.240695
231   231    79   632    411   96        4 -51.240695
232   232    39   632    411   96        4 -51.240695
233   233    41   632    411   96        4 -51.240695
234   234    15   634    415   96        5 -47.240695
235   235    23   634    415   96        5 -47.240695
236   236    14   634    415   96        5 -47.240695
237   237     7   635    427   96       13 -35.240695
238   238    24   636    424   96       11 -38.240695
239   239     3   638    525   96       62  62.759305
240   240     1   638    525   96       62  62.759305
241   241     2   640    521   96       61  58.759305
242   242     1   640    521   96       61  58.759305
243   243     0   640    521   96       61  58.759305
244   244     3   641    518   96       60  55.759305
245   245     8   641    518   96       60  55.759305
246   246     1   642    495   96       50  32.759305
247   247     2   642    495   96       50  32.759305
248   248     0   642    495   96       50  32.759305
249   249     8   643    495   96       50  32.759305
250   250     3   643    495   96       50  32.759305
251   251    14   643    495   96       50  32.759305
252   252    16   643    495   96       50  32.759305
253   253    18   643    495   96       50  32.759305
254   254    11   643    495   96       50  32.759305
255   255    13   643    495   96       50  32.759305
256   256     6   645    460   96       30  -2.240695
257   257     7   645    460   96       30  -2.240695
258   258    10   645    460   96       30  -2.240695
259   259     5   647    442   96       19 -20.240695
260   260     7   647    442   96       19 -20.240695
261   261    25   648    443   96       20 -19.240695
262   262    11   648    443   96       20 -19.240695
263   263     6   648    443   96       20 -19.240695
264   264     4   648    443   96       20 -19.240695
265   265     7   648    443   96       20 -19.240695
266   266     4   650    425   96       12 -37.240695
267   267     6   650    425   96       12 -37.240695
268   268     2   650    425   96       12 -37.240695
269   269     5   651    439   96       18 -23.240695
270   270     3   651    439   96       18 -23.240695
271   271     7   651    439   96       18 -23.240695
272   272     3   652    444   96       21 -18.240695
273   273     1   701    450   97       25 -12.240695
274   274     4   701    450   97       25 -12.240695
275   275     4   701    450   97       25 -12.240695
276   276     2   701    450   97       25 -12.240695
277   277     5   701    450   97       25 -12.240695
278   278     3   702    446   97       22 -16.240695
279   279     0   702    446   97       22 -16.240695
280   280     3   702    446   97       22 -16.240695
281   281     1   702    446   97       22 -16.240695
282   282     2   702    446   97       22 -16.240695
283   283     3   702    446   97       22 -16.240695
284   284     1   704    472   97       36   9.759305
285   285     0   704    472   97       36   9.759305
286   286     4   704    472   97       36   9.759305
287   287     0   704    472   97       36   9.759305
288   288     0   704    472   97       36   9.759305
289   289     0   705    472   97       36   9.759305
290   290     0   706    460   97       30  -2.240695
291   291     0   706    460   97       30  -2.240695
292   292     0   706    460   97       30  -2.240695
293   293     1   708    442   97       19 -20.240695
294   294     3   708    442   97       19 -20.240695
295   295     4   708    442   97       19 -20.240695
296   296     0   708    442   97       19 -20.240695
297   297     4   708    442   97       19 -20.240695
298   298     2   708    442   97       19 -20.240695
299   299     0   709    525   97       62  62.759305
300   300     0   709    525   97       62  62.759305
301   301     1   709    525   97       62  62.759305
302   302     0   710    533   97       63  70.759305
303   303     1   710    533   97       63  70.759305
304   304     2   710    533   97       63  70.759305
305   305     0   710    533   97       63  70.759305
306   306     0   710    533   97       63  70.759305
307   307     0   710    533   97       63  70.759305
308   308     1   711    513   97       57  50.759305
309   309     0   711    513   97       57  50.759305
310   310     0   711    513   97       57  50.759305
311   311     1   711    513   97       57  50.759305
312   312     1   711    513   97       57  50.759305
313   313     0   711    513   97       57  50.759305
314   314     0   711    513   97       57  50.759305
315   315     0   712    514   97       58  51.759305
316   316     0   712    514   97       58  51.759305
317   317     0   713    511   97       56  48.759305
318   318     0   713    511   97       56  48.759305
319   319     1   713    511   97       56  48.759305
320   320     0   713    511   97       56  48.759305
321   321     0   713    511   97       56  48.759305
322   322     0   714    511   97       56  48.759305
323   323     0   714    511   97       56  48.759305
324   324     1   714    511   97       56  48.759305
325   325     0   714    511   97       56  48.759305
326   326     0   714    511   97       56  48.759305
327   327     0   714    511   97       56  48.759305
328   328     0   715    496   97       51  33.759305
329   329     0   715    496   97       51  33.759305
330   330     0   715    496   97       51  33.759305
331   331     0   715    496   97       51  33.759305
332   332     1   716    494   97       49  31.759305
333   333     0   716    494   97       49  31.759305
334   334     0   717    494   97       49  31.759305
335   335     0   717    494   97       49  31.759305
336   336     0   717    494   97       49  31.759305
337   337     2   718    411   97        4 -51.240695
338   338     4   718    411   97        4 -51.240695
339   339     4   718    411   97        4 -51.240695
340   340     1   718    411   97        4 -51.240695
341   341     2   718    411   97        4 -51.240695
342   342     2   719    411   97        4 -51.240695
343   343     1   719    411   97        4 -51.240695
344   344     4   719    411   97        4 -51.240695
345   345     1   719    411   97        4 -51.240695
346   346     3   719    411   97        4 -51.240695
347   347     3   719    411   97        4 -51.240695
348   348     2   720    423   97       10 -39.240695
349   349     0   720    423   97       10 -39.240695
350   350     3   721    424   97       11 -38.240695
351   351     2   722    403   97        1 -59.240695
352   352     0   722    403   97        1 -59.240695
353   353     1   722    403   97        1 -59.240695
354   354     0   723    409   97        2 -53.240695
355   355     3   723    409   97        2 -53.240695
356   356     1   723    409   97        2 -53.240695
357   357    10   724    434   97       16 -28.240695
358   358     4   724    434   97       16 -28.240695
359   359     1   724    434   97       16 -28.240695
360   360     2   725    477   97       39  14.759305
361   361     0   725    477   97       39  14.759305
362   362     1   725    477   97       39  14.759305
363   363     0   727    472   97       36   9.759305
364   364     0   728    468   97       34   5.759305
365   365     0   728    468   97       34   5.759305
366   366     0   729    470   97       35   7.759305
367   367     0   730    486   97       43  23.759305
368   368     0   731    495   97       50  32.759305
369   369     0   731    495   97       50  32.759305
370   370     0   731    495   97       50  32.759305
371   371     0   731    495   97       50  32.759305
372   372     0   731    495   97       50  32.759305
373   373     0   732    483   97       41  20.759305
374   374     0   732    483   97       41  20.759305
375   375     2   732    483   97       41  20.759305
376   376     2   733    442   97       19 -20.240695
377   377     2   733    442   97       19 -20.240695
378   378     0   734    457   97       28  -5.240695
379   379     4   736    457   97       28  -5.240695
380   380     5   736    457   97       28  -5.240695
381   381     2   737    457   97       28  -5.240695
382   382     3   737    457   97       28  -5.240695
383   383     2   737    457   97       28  -5.240695
384   384     2   737    457   97       28  -5.240695
385   385     1   737    457   97       28  -5.240695
386   386     2   737    457   97       28  -5.240695
387   387     0   737    457   97       28  -5.240695
388   388     2   738    464   97       31   1.759305
389   389     0   738    464   97       31   1.759305
390   390     1   738    464   97       31   1.759305
391   391     0   739    433   97       15 -29.240695
392   392     3   739    433   97       15 -29.240695
393   393     1   739    433   97       15 -29.240695
394   394     0   739    433   97       15 -29.240695
395   395     0   740    442   97       19 -20.240695
396   396     0   740    442   97       19 -20.240695
397   397     0   741    433   97       15 -29.240695
398   398     1   741    433   97       15 -29.240695
399   399     0   741    433   97       15 -29.240695
400   400     0   742    430   97       14 -32.240695
401   401     0   742    430   97       14 -32.240695
402   402     2   743    450   97       25 -12.240695
403   403     0   743    450   97       25 -12.240695

JuliaOpt packages

One of the areas in which Julia shines is optimization packages. I mostly do nonlinear optimization subject to box constraints and use the NLopt package. Many other types of optimization problems can be addressed with the JuMP package.

A recent addition is the JuliaDiff organization that provides several types of automatic differentiation packages for Julia.